@import (reference) "../../../../app/less/app-icons";
@import (reference) 'config';
@import (reference) 'icons';

@leftPanelWidth: 330px;
@leftPanelRightMargin: 10px;

.leasing-page {
  display: flex;
  flex-direction: row;
  width: 100%;
  height: 100%;
  max-height: calc(~'100vh - 90px');

  w-transaction {
    .transaction {
      padding-left: 10px;
    }
  }

  .left-panel {
    height: 100%;
    max-height: calc(~'100vh - 90px');
    overflow-y: auto;
    width: @leftPanelWidth;
    margin-right: @leftPanelRightMargin;
  }

  .btn-wrap.btn-group {
    justify-content: flex-start;
    padding: 0;
    align-items: center;
    height: 42px;

    .btn.btn-radio {
      font-size: 15px;
      font-family: @font-roboto-medium;
      &:first-letter {
        text-transform: uppercase;
      }
    }
  }

  w-scroll-box {
    border-radius: 0 0 @border-radius @border-radius;
    height: calc(~'100vh - ' 130px);

    .scroll-list {
      height: 100%;
    }
  }

  .transaction-item > .date {
    display: none;
  }

  .transactions-container {
    width: calc(~'100% - '@leftPanelWidth + @leftPanelRightMargin);
    position: relative;
  }

  .chart-wrapper {
    display: flex;
    width: 100%;
    justify-content: center;
  }

  .legend-container {
    .legend-item {
      position: relative;
      display: flex;
      flex-direction: row;
      align-items: center;
      justify-content: space-between;
      padding-bottom: 10px;

      &:not(:first-child) {
        margin-top: 10px;
      }

      .part {
        display: flex;
        align-items: center;

        .legend-color {
          width: 12px;
          height: 12px;
          border-radius: 100%;
        }
      }

      &::after {
        content: '';
        position: absolute;
        width: 100%;
        bottom: 0;
        height: 0;
        border-bottom: 1px dashed @color-basic-200;
      }
    }
  }

  .description-split {
    margin: 30px 0;
    height: 0;
    border-bottom: 1px dashed @color-basic-100;
  }

  .icon-description {
    position: relative;
    padding-left: 60px;

    &::before {
      content: '';
      position: absolute;
      left: 0;
      top: 0;
      width: 50px;
      height: 48px;
      background-image: @leasing-note-icon;
    }
  }
}

@media screen and (max-width: @width-media-normal) {
  .transaction-item .locale-address {
    display: none;
  }
}

@media screen and (max-width: 768px) {
  .leasing-page {
    height: auto;
    display: block;
    overflow: visible;

    w-scroll-box {
      margin-bottom: 10px;
      min-height: 300px;
    }

    .left-panel {
      width: 100%;
      max-height: 100%;
      overflow-y: visible;
    }

    .transactions-container {
      width: 100%;
    }

    w-transaction .transaction {
      height: auto;
      min-height: 74px;
    }
  }

  .expandable-block {
    margin-bottom: 10px;
  }
}

@media screen and (max-height: 355px) {
  .leasing-page {
    max-height: 100%;

    .left-panel {
      min-height: 263px;
    }

    w-scroll-box {
      min-height: 223px;
    }
  }
}
